﻿function getCraft()
{
	//从服务器获取草稿，还没实现。
	return '';
}

window.UEDITOR_HOME_URL='/public/js/lib/editor/';
function initEditor(eid){
	initText=getCraft();
    var editor = new baidu.editor.ui.Editor({
		maxUndoCount:40,
		initialStyle: 'body{margin:8px;font-family:"Microsoft YaHei","SimSun";font-size:16px;}',
		initialContent:initText,
		pageBreakTag:'_page_break_tag_',
		elementPathEnabled:false,
		maximumWords:50000,
		autoFloatEnabled:false,
		toolbars:[['Source', '|',
                'Bold', 'Italic', 'Underline', 'StrikeThrough', '|',  'ForeColor', 'BackColor', '|', 'FontFamily', 'FontSize', '|',
                'Link', 'Unlink', '|', 'InsertImage', 'Emotion', 'InsertVideo']]
	});
    editor.render(eid);
}
